import React, { Component } from 'react';
import SourceItem from './SourceItem';

export default class DropSource extends Component {
  state = {
    defaultList: [
      {
        name: '刺客-李白',
      },
      {
        name: '射手-虞姬',
      },
      {
        name: '战士-亚瑟',
      },
    ],
  };

  render() {
    const { defaultList } = this.state;

    return (
      <div
        style={{
          width: 400,
          height: 500,
          overflow: 'auto',
          backgroundColor: 'rgba(210,150,102,0.5)',
        }}
      >
        {defaultList.map((d, index) => (
          <SourceItem key={index} item={d} name="zhangsan" />
        ))}
      </div>
    );
  }
}
